package com.ursu.client.gin;


//import com.google.inject.Singleton;
import com.gwtplatform.mvp.client.gin.AbstractPresenterModule;
import com.gwtplatform.mvp.client.gin.DefaultModule;
import com.ursu.client.place.ClientPlaceManager;
import com.ursu.client.place.DefaultPlace;
import com.ursu.client.place.NameTokens;
import com.ursu.client.presenter.LoginPagePresenter;
import com.ursu.client.view.CreateAccountView;
import com.ursu.client.view.CreateAdminView;
import com.ursu.client.view.FirstApplicationView;
import com.ursu.client.view.LoginPageView;
import com.ursu.client.view.SecondPageView;
import com.ursu.client.presenter.CreateAccountPresenter;
import com.ursu.client.presenter.FirstApplicationPresenter;
import com.ursu.client.presenter.SecondPagePresenter;
import com.ursu.client.presenter.CreateAdminPresenter;


public class ClientModule extends AbstractPresenterModule {

	@Override
	protected void configure() {
		install(new DefaultModule(ClientPlaceManager.class));

		bindPresenter(LoginPagePresenter.class, LoginPagePresenter.MyView.class,
				LoginPageView.class, LoginPagePresenter.MyProxy.class);

		bindConstant().annotatedWith(DefaultPlace.class)
				.to(NameTokens.loginpage);

		bindPresenter(CreateAccountPresenter.class,
				CreateAccountPresenter.MyView.class, CreateAccountView.class,
				CreateAccountPresenter.MyProxy.class);
		

		



		bindPresenter(FirstApplicationPresenter.class,
				FirstApplicationPresenter.MyView.class,
				FirstApplicationView.class,
				FirstApplicationPresenter.MyProxy.class);

		bindPresenter(SecondPagePresenter.class,
				SecondPagePresenter.MyView.class, SecondPageView.class,
				SecondPagePresenter.MyProxy.class);

		bindPresenter(CreateAdminPresenter.class,
				CreateAdminPresenter.MyView.class, CreateAdminView.class,
				CreateAdminPresenter.MyProxy.class);
	}
}
